.class public Lcom/donson/momark/view/view/v;
.super Landroid/view/View;


# instance fields
.field public a:I

.field private b:I

.field private c:I

.field public d:I

.field private e:Lcom/donson/momark/view/view/x;

.field private f:Ljava/lang/String;

.field private g:Landroid/graphics/Bitmap;

.field private h:I

.field private i:Ljava/lang/String;

.field private j:I

.field private k:Landroid/content/Context;

.field private l:I

.field private m:Landroid/graphics/Rect;

.field private n:Z

.field private o:Lcom/donson/momark/a/u;

.field private p:I

.field private w:J


# direct methods
.method public constructor <init>(Landroid/content/Context;I)V
    .locals 2

    const/4 v1, 0x0

    invoke-direct {p0, p1}, Landroid/view/View;-><init>(Landroid/content/Context;)V

    iput v1, p0, Lcom/donson/momark/view/view/v;->a:I

    iput v1, p0, Lcom/donson/momark/view/view/v;->d:I

    const/4 v0, 0x0

    iput-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iput-boolean v1, p0, Lcom/donson/momark/view/view/v;->n:Z

    iput-object p1, p0, Lcom/donson/momark/view/view/v;->k:Landroid/content/Context;

    iput p2, p0, Lcom/donson/momark/view/view/v;->p:I

    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Landroid/util/AttributeSet;)V
    .locals 2

    const/4 v1, 0x0

    invoke-direct {p0, p1, p2}, Landroid/view/View;-><init>(Landroid/content/Context;Landroid/util/AttributeSet;)V

    iput v1, p0, Lcom/donson/momark/view/view/v;->a:I

    iput v1, p0, Lcom/donson/momark/view/view/v;->d:I

    const/4 v0, 0x0

    iput-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iput-boolean v1, p0, Lcom/donson/momark/view/view/v;->n:Z

    iput-object p1, p0, Lcom/donson/momark/view/view/v;->k:Landroid/content/Context;

    return-void
.end method

.method static synthetic a(Lcom/donson/momark/view/view/v;)Lcom/donson/momark/view/view/x;
    .locals 1

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    return-object v0
.end method

.method static synthetic a(Lcom/donson/momark/view/view/v;J)V
    .locals 0

    iput-wide p1, p0, Lcom/donson/momark/view/view/v;->w:J

    return-void
.end method

.method static synthetic a(Lcom/donson/momark/view/view/v;Lcom/donson/momark/view/view/x;)V
    .locals 0

    iput-object p1, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    return-void
.end method

.method static synthetic d(Lcom/donson/momark/view/view/v;)Ljava/lang/String;
    .locals 1

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->f:Ljava/lang/String;

    return-object v0
.end method

.method private d()V
    .locals 1

    invoke-virtual {p0}, Lcom/donson/momark/view/view/v;->a()V

    const/4 v0, 0x0

    iput v0, p0, Lcom/donson/momark/view/view/v;->b:I

    const/4 v0, 0x1

    iput v0, p0, Lcom/donson/momark/view/view/v;->d:I

    new-instance v0, Lcom/donson/momark/view/view/b;

    invoke-direct {v0, p0}, Lcom/donson/momark/view/view/b;-><init>(Lcom/donson/momark/view/view/v;)V

    invoke-virtual {v0}, Lcom/donson/momark/view/view/b;->start()V

    return-void
.end method

.method static synthetic e(Lcom/donson/momark/view/view/v;)Lcom/donson/momark/a/u;
    .locals 1

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->o:Lcom/donson/momark/a/u;

    return-object v0
.end method

.method private e()V
    .locals 2

    iget v0, p0, Lcom/donson/momark/view/view/v;->b:I

    add-int/lit8 v0, v0, 0x1

    iput v0, p0, Lcom/donson/momark/view/view/v;->b:I

    iget v0, p0, Lcom/donson/momark/view/view/v;->b:I

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    invoke-virtual {v1}, Lcom/donson/momark/view/view/x;->a()I

    move-result v1

    if-lt v0, v1, :cond_0

    const/4 v0, 0x0

    iput v0, p0, Lcom/donson/momark/view/view/v;->b:I

    :cond_0
    return-void
.end method


# virtual methods
.method public a()V
    .locals 1

    const/4 v0, 0x0

    iput-object v0, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    return-void
.end method

.method public a(ILjava/lang/String;Landroid/graphics/Bitmap;)V
    .locals 3

    const/4 v0, 0x0

    iput v0, p0, Lcom/donson/momark/view/view/v;->c:I

    iput p1, p0, Lcom/donson/momark/view/view/v;->l:I

    iput-object p2, p0, Lcom/donson/momark/view/view/v;->i:Ljava/lang/String;

    iput v0, p0, Lcom/donson/momark/view/view/v;->a:I

    iput v0, p0, Lcom/donson/momark/view/view/v;->d:I

    iput-object p3, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    if-nez v0, :cond_0

    const-string v0, "donson.momark"

    const-string v1, " NewGifView.setGif 40020\uff1aadvertise gif bitmap java.net.SocketException: Connection reset by peer error."

    invoke-static {v0, v1}, Lcom/donson/momark/util/t;->d(Ljava/lang/String;Ljava/lang/String;)V

    new-instance v0, Lcom/donson/momark/a/a/y;

    const v1, 0x9c54

    invoke-direct {v0, v1}, Lcom/donson/momark/a/a/y;-><init>(I)V

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->o:Lcom/donson/momark/a/u;

    invoke-virtual {v1, v0}, Lcom/donson/momark/a/u;->a(Lcom/donson/momark/a/a/y;)V

    :goto_0
    return-void

    :cond_0
    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    invoke-virtual {v0}, Landroid/graphics/Bitmap;->getHeight()I

    move-result v0

    iput v0, p0, Lcom/donson/momark/view/view/v;->j:I

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    invoke-virtual {v0}, Landroid/graphics/Bitmap;->getWidth()I

    move-result v0

    iput v0, p0, Lcom/donson/momark/view/view/v;->h:I

    new-instance v0, Landroid/widget/LinearLayout$LayoutParams;

    iget v1, p0, Lcom/donson/momark/view/view/v;->h:I

    iget v2, p0, Lcom/donson/momark/view/view/v;->j:I

    invoke-direct {v0, v1, v2}, Landroid/widget/LinearLayout$LayoutParams;-><init>(II)V

    invoke-virtual {p0, v0}, Lcom/donson/momark/view/view/v;->setLayoutParams(Landroid/view/ViewGroup$LayoutParams;)V

    goto :goto_0
.end method

.method public a(ILjava/lang/String;Lcom/donson/momark/a/u;)V
    .locals 2

    iput-object p2, p0, Lcom/donson/momark/view/view/v;->f:Ljava/lang/String;

    iput-object p3, p0, Lcom/donson/momark/view/view/v;->o:Lcom/donson/momark/a/u;

    invoke-static {}, Lcom/donson/momark/util/r;->a()Lcom/donson/momark/util/r;

    move-result-object v0

    const/4 v1, 0x7

    invoke-virtual {v0, p2, v1, p3}, Lcom/donson/momark/util/r;->a(Ljava/lang/String;ILcom/donson/momark/a/u;)Landroid/graphics/Bitmap;

    move-result-object v0

    invoke-virtual {p0, p1, p2, v0}, Lcom/donson/momark/view/view/v;->a(ILjava/lang/String;Landroid/graphics/Bitmap;)V

    return-void
.end method

.method protected onDraw(Landroid/graphics/Canvas;)V
    .locals 7

    const/4 v4, 0x2

    const/4 v3, 0x1

    const/4 v1, 0x0

    const/4 v6, 0x0

    invoke-super {p0, p1}, Landroid/view/View;->onDraw(Landroid/graphics/Canvas;)V

    new-instance v0, Landroid/graphics/Rect;

    invoke-direct {v0}, Landroid/graphics/Rect;-><init>()V

    iput-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iput v1, v0, Landroid/graphics/Rect;->left:I

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iput v1, v0, Landroid/graphics/Rect;->top:I

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->k:Landroid/content/Context;

    check-cast v0, Landroid/app/Activity;

    new-instance v1, Landroid/util/DisplayMetrics;

    invoke-direct {v1}, Landroid/util/DisplayMetrics;-><init>()V

    invoke-virtual {v0}, Landroid/app/Activity;->getWindowManager()Landroid/view/WindowManager;

    move-result-object v0

    invoke-interface {v0}, Landroid/view/WindowManager;->getDefaultDisplay()Landroid/view/Display;

    move-result-object v0

    invoke-virtual {v0, v1}, Landroid/view/Display;->getMetrics(Landroid/util/DisplayMetrics;)V

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    if-nez v0, :cond_1

    const-string v0, "donson.momark"

    const-string v1, " NewGifView.setGif 40020\uff1aadvertise gif bitmap java.net.SocketException: Connection reset by peer error."

    invoke-static {v0, v1}, Lcom/donson/momark/util/t;->d(Ljava/lang/String;Ljava/lang/String;)V

    new-instance v0, Lcom/donson/momark/a/a/y;

    const v1, 0x9c54

    invoke-direct {v0, v1}, Lcom/donson/momark/a/a/y;-><init>(I)V

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->o:Lcom/donson/momark/a/u;

    invoke-virtual {v1, v0}, Lcom/donson/momark/a/u;->a(Lcom/donson/momark/a/a/y;)V

    :cond_0
    :goto_0
    return-void

    :cond_1
    iget-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iget v1, v1, Landroid/util/DisplayMetrics;->widthPixels:I

    iput v1, v0, Landroid/graphics/Rect;->right:I

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->k:Landroid/content/Context;

    const/16 v2, 0x32

    invoke-static {v1, v2}, Lcom/donson/momark/util/u;->a(Landroid/content/Context;I)I

    move-result v1

    iput v1, v0, Landroid/graphics/Rect;->bottom:I

    iget v0, p0, Lcom/donson/momark/view/view/v;->d:I

    if-nez v0, :cond_2

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    invoke-virtual {p1, v0, v6, v1, v6}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Rect;Landroid/graphics/Rect;Landroid/graphics/Paint;)V

    invoke-direct {p0}, Lcom/donson/momark/view/view/v;->d()V

    invoke-virtual {p0}, Lcom/donson/momark/view/view/v;->invalidate()V

    goto :goto_0

    :cond_2
    iget v0, p0, Lcom/donson/momark/view/view/v;->d:I

    if-ne v0, v3, :cond_3

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    invoke-virtual {p1, v0, v6, v1, v6}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Rect;Landroid/graphics/Rect;Landroid/graphics/Paint;)V

    invoke-virtual {p0}, Lcom/donson/momark/view/view/v;->invalidate()V

    goto :goto_0

    :cond_3
    iget v0, p0, Lcom/donson/momark/view/view/v;->d:I

    if-ne v0, v4, :cond_0

    iget v0, p0, Lcom/donson/momark/view/view/v;->a:I

    if-ne v0, v3, :cond_4

    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    invoke-virtual {p1, v0, v6, v1, v6}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Rect;Landroid/graphics/Rect;Landroid/graphics/Paint;)V

    goto :goto_0

    :cond_4
    iget v0, p0, Lcom/donson/momark/view/view/v;->a:I

    if-ne v0, v4, :cond_7

    invoke-static {}, Ljava/lang/System;->currentTimeMillis()J

    move-result-wide v0

    iget-wide v2, p0, Lcom/donson/momark/view/view/v;->w:J

    iget-object v4, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    iget v5, p0, Lcom/donson/momark/view/view/v;->b:I

    invoke-virtual {v4, v5}, Lcom/donson/momark/view/view/x;->a(I)I

    move-result v4

    int-to-long v4, v4

    add-long/2addr v2, v4

    cmp-long v0, v2, v0

    if-gez v0, :cond_5

    iget-wide v0, p0, Lcom/donson/momark/view/view/v;->w:J

    iget-object v2, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    iget v3, p0, Lcom/donson/momark/view/view/v;->b:I

    invoke-virtual {v2, v3}, Lcom/donson/momark/view/view/x;->a(I)I

    move-result v2

    int-to-long v2, v2

    add-long/2addr v0, v2

    iput-wide v0, p0, Lcom/donson/momark/view/view/v;->w:J

    invoke-direct {p0}, Lcom/donson/momark/view/view/v;->e()V

    :cond_5
    iget-object v0, p0, Lcom/donson/momark/view/view/v;->e:Lcom/donson/momark/view/view/x;

    iget v1, p0, Lcom/donson/momark/view/view/v;->b:I

    invoke-virtual {v0, v1}, Lcom/donson/momark/view/view/x;->d(I)Landroid/graphics/Bitmap;

    move-result-object v0

    if-eqz v0, :cond_6

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    invoke-virtual {p1, v0, v6, v1, v6}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Rect;Landroid/graphics/Rect;Landroid/graphics/Paint;)V

    :cond_6
    invoke-virtual {p0}, Lcom/donson/momark/view/view/v;->invalidate()V

    goto :goto_0

    :cond_7
    iget-object v0, p0, Lcom/donson/momark/view/view/v;->g:Landroid/graphics/Bitmap;

    iget-object v1, p0, Lcom/donson/momark/view/view/v;->m:Landroid/graphics/Rect;

    invoke-virtual {p1, v0, v6, v1, v6}, Landroid/graphics/Canvas;->drawBitmap(Landroid/graphics/Bitmap;Landroid/graphics/Rect;Landroid/graphics/Rect;Landroid/graphics/Paint;)V

    goto/16 :goto_0
.end method
